﻿<%@page contentType="text/vnd.wap.wml; charset=utf-8"%>
<%@ page import="java.io.*"%>
<%@ page import="java.sql.*"%>
<%@ page import="java.util.*"%>
<%@ page import="java.text.*"%>
<%@ page import="common.*"%>
<%@ page import="wapbean.*"%>
<%@ page import="business.*"%>

<?xml version="1.0" encoding="utf-8"?>  
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org//DTD//wml_1.1.xml">   
<wml> 
<card id="card1" title="游戏名称">
<p align="left">
  
 <img src="/game3.0/img/logo.png" alt=""/><br />   
	
   <%       String title=(String)session.getAttribute("title");
            URLservlet urlser=new URLservlet();
            String ip=urlser.getIpAddr(request);
             String[] pip=ip.split("\\.");
              for(int i=0;i<pip.length;i++){
			//  System.out.println("pip="+pip[i]);  
		  }
               String ip1=pip[0];
               int aa=ip1.length();
        //      System.out.println("ip1ip1="+aa);
	    //    System.out.println("&&ip&&="+ip);
         //获取 当前时间
		  GetDateTime GetDateTime = new GetDateTime();
	      String nowtime = GetDateTime.getDate();
		  
          String CategoryID = request.getParameter("CategoryID");
		  String MobileModelID = request.getParameter("MobileModelID");
		  String ProviderID = request.getParameter("ProviderID");  
          String contentid = request.getParameter("contentId");
          String cpId = request.getParameter("cpId");
		  String ContentResourceID = request.getParameter("ContentResourceID");
		  String submitCode = request.getParameter("submitCode");
		   String gameresourceid = request.getParameter("gameresourceid");
	//	  String gamename = request.getParameter("gamename");
	//	  String name = new String(gamename.getBytes("iso-8859-1"),"utf-8");
		  
		 // System.out.println("CategoryID=========="+CategoryID);
		 // System.out.println("MobileModelID========="+MobileModelID);
	     // System.out.println("ProviderID=============="+ProviderID);
	     // System.out.println("contentid============="+contentid);
		 // System.out.println("gamename============="+gamename);  
		   WapcategoryFactory Fac = new WapcategoryFactory();
		    ContentFactory fac1 = new ContentFactory();
			  WapcontentBean wbea=fac1.getconnectNum(contentid);
			    SpinFoBean fo=fac1.getspType(submitCode);  
	   		    String spid=fo.getProviderId();  
	   		    String price=fo.getPrice();
	   		  UseraccesslogBean be=new UseraccesslogBean();
			  Allbean be1=new Allbean();
			  WapcontentBean be2=new WapcontentBean();
	                    be.setContentID(contentid); 
	   		            be.setCreateDate(nowtime);
	   		            be.setContentResourceID(ContentResourceID);
	   			        be.setMobileModelID(MobileModelID);
	   		            be.setCategoryID(CategoryID);
	   			        be.setProviderID(ProviderID);
	   			        be.setUserIp(ip);
	   			        be.setCpId(cpId);      
	   		            be.infor();
						be2.setUsedNum(wbea.getUsedNum());
	   		            be2.updatecontenUsedNum(contentid);   
		   Allbean bea =Fac.getContent(contentid); 
		  //  System.out.println("bea============="+bea); 
		//   Allbean bea1=Fac.getWapcategoryBeanMO(contentid);   
		 //  String GameResourceID=bea1.getGameResourceID();  
		 //  System.out.println("GameResourceID============="+GameResourceID); 
		   String file=MobileModelID+";"+ProviderID+";"+CategoryID+";"+ContentResourceID+";"+gameresourceid+";"+ip+";"+cpId+";"+spid+";"+price+";"+submitCode; 
	%>     
    [<%=wbea.getTitle()%>]<br />   
	<%if(bea==null||bea.equals("")){ %>   
	<%}else{ %>
	 <img src="/game2.0<%=bea.getFileDir()%>" width="100" height="80" align="top" alt=""/><br /> 
	  	 
   	    触摸屏:<%if(bea.getTouchEnabled().equals("0")){%>
   	     <%out.println("不支持"); %> 
   	   <%}
   	   else{%>
   	    <%out.println("支持"); %>          
   	   <%}  %><br />         
   	    [简介]:<%=bea.getDescription()%>.......<br />    
	 <%} %>     
	       
   	<%if(fo.getSpType().equals("SMS")){ %>                               
	 <a href="/game3.0/GameuploadServlet?contentid=<%=contentid%>&amp;CategoryID=<%=file%>">进入下载</a>  
	 <%}
	 else{ %>          
	 <a href="http://wap.monternet.com/reversesubscribe?SPID=900695&amp;ServiceID=03203922&amp;SPURL=http://wap.yidatone.com/wap/ring/ylwzx_jc_detail_at.jsp?qudao=one1005&amp;backurl=http://www.mobi5cool.com/FeeWAP/in.aspx?d=10770001&amp;msg=WAPXXBP201234567891234ZY29&amp;ftype=02&amp;sreid=001&amp;p=zy0001&amp;rid=<%=contentid%>&amp;cid=<%=file%>">下载</a>
	 <%} %> <br/> 
	 <!-- <a href="http://211.94.188.131:8090<%//=bea1.getFileDir()%>">下载3</a> -->     
	 
		<jsp:include page="../includes/video_bottom.jsp"/><!-- 视频 -->
		<%@ include file="../includes/book.jsp" %><!-- 精彩图书 -->
		<%@ include file="../includes/shop_navi.jsp" %><!-- 商城分类 -->
		<%@ include file="../includes/shop_hot.jsp" %><!--商城热销-->
		
   	<%if(fo.getSpType().equals("SMS")){ %>                               
	 <a href="/game3.0/GameuploadServlet?contentid=<%=contentid%>&amp;CategoryID=<%=file%>">进入下载</a>  
	 <%}
	 else{ %>          
	 <a href="http://wap.monternet.com/reversesubscribe?SPID=900695&amp;ServiceID=03203922&amp;SPURL=http://wap.yidatone.com/wap/ring/ylwzx_jc_detail_at.jsp?qudao=one1005&amp;backurl=http://www.mobi5cool.com/FeeWAP/in.aspx?d=10770001&amp;msg=WAPXXBP201234567891234ZY29&amp;ftype=02&amp;sreid=001&amp;p=zy0001&amp;rid=<%=contentid%>&amp;cid=<%=file%>">下载</a>
	 <%} %> <br/> 
    <!--<a href="/game3.0/wappages/scoregame.jsp?tid=<%=contentid%>">游戏评测</a>   
	<br /> -->
	<%//if(title.equals("角色")){ %>  
	<!--<a href="/game3.0/wappages/functiongame.jsp?CategoryID=<%=CategoryID%>&amp;MobileModelID=<%=MobileModelID%>&amp;ProviderID=<%=ProviderID%>&amp;contentId=<%=contentid%>&amp;ContentResourceID=<%=ContentResourceID%>&amp;cpId=<%=cpId%>&amp;submitCode=<%=submitCode%>">游戏攻略</a><br /> -->      
<%//}else{}%>
	 
	<a href="/game3.0/wappages/gamelistPage.jsp?CategoryID=<%=CategoryID%>&amp;MobileModelID=<%=MobileModelID%>&amp;ProviderID=<%=ProviderID%>">返回</a> 
  
	<br />   

</p>  
</card>
</wml>  